package cn.melon.view.admin.library.ctr;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import cn.melon.mod.library.LibraryRequest;
import cn.melon.view.admin.library.AddBookDig;

public class AddbookCtr implements ActionListener {

    private AddBookDig addBookDig = null;
    
    
    public AddbookCtr(AddBookDig dig){
        this.addBookDig = dig; 
    }
    @Override
    public void actionPerformed(ActionEvent e) {
        switch (e.getActionCommand()) {
        case "确定":
            LibraryRequest libraryRequest = new LibraryRequest();
            libraryRequest.addInfo(addBookDig.getBook());
            addBookDig.setVisible(false);
            break;
        case "取消":
            addBookDig.setVisible(false);
            break;
        default:
            break;
        }

    }

}
